package com.ruoyi.project.lely.controller;


import com.ruoyi.common.R;
import com.ruoyi.project.lely.bean.dto.LyWechatLoginDTO;
import com.ruoyi.project.lely.service.LyCartService;
import com.ruoyi.project.lely.service.LyCategoryService;
import com.ruoyi.project.lely.service.LyWechatService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author luoyong
 * @Desc: 微信相关
 * @since 2022-01-13
 */
@Api(tags = "Mini-微信相关")
@RestController
@RequestMapping("/mini/wechat")
public class WechatController {

    @Autowired
    private LyWechatService wechatService;

    @ApiOperation("登录")
    @PostMapping(value = {"/login"})
    public R login(@RequestBody LyWechatLoginDTO dto) {
        return wechatService.login(dto);
    }


}

